package com.wn.service.impl;

import com.wn.annonation.MyLimit;
import com.wn.annonation.MyRedisCache;
import com.wn.service.MemberService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

/**
 * @author yellow Docter
 * @date 2022 -10-28
 * @desc
 */
@Service
@Slf4j
public class MemberServiceImpl implements MemberService {

    @MyRedisCache("mycache:list")
    @MyLimit(value = 5)       //对这个方法进行限流
    @Override
    public String getMemberById(Integer id) {
        log.info("service 调用了方法");
        return "会员id是:" + id;
    }

}
